﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Gnosis.Alexandria.Model.Commands
{
    public class SelectTextBuilder
        : CommandBuilderBase
    {
        public SelectTextBuilder(string recordName)
            : base(null)
        {
            AppendFormat("SELECT * FROM {0}", recordName);
        }

        public SelectTextBuilder(IIdentifiable record)
            : base(record)
        {
            AppendFormat("SELECT * FROM {0}", record.RecordName);
        }

        public SelectTextBuilder(IIdentifiable record, long id)
            : base(record)
        {
            AppendFormat("SELECT * FROM {0}", record.RecordName);
            AppendWhereClause(id);
        }
    }
}
